﻿using SqlSugar;

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Application.Core.Entity;

// 多对多中间表
[SugarTable("UserPermission", TableDescription = "用户权限关联表")]
public class UserPermission
{
	/// <summary>用户 Id</summary>
	[SugarColumn(IsPrimaryKey = true, ColumnDescription = "用户Id")]
	public int UserId { get; set; }

	/// <summary>权限 Id</summary>
	[SugarColumn(IsPrimaryKey = true, ColumnDescription = "权限Id")]
	public int PermissionId { get; set; }

	/// <summary>是否为只读权限</summary>
	[SugarColumn(ColumnDescription = "是否为只读权限")]
	public bool OnlyRead { get; set; } = false;
}
